﻿using System;
using Evpo.ContactData.Common;
using System.Data.SqlClient;
using System.Collections.Generic;

namespace Evpo.ContactData.Data
{
    public class DictionaryItem : DataObject, IDictionaryItem
    {
        public DictionaryItem()
        {
        }

        #region Fields
        #endregion

        #region Properties
        public int ID
        {
            get;
            set;
        }

        public string Name
        {
            get;
            set;
        }

        #endregion

        #region Methods
        #endregion Methods

        internal override int PrimaryKeyValue
        {
            get
            {
                return ID;
            }
            set
            {
                ID = value;
            }
        }

        internal override void FillParametersToSave(List<SqlParameter> paramList)
        {
            DictionaryItemAdapter.FillParametersToSave(this, paramList);
        }

        internal override void FillFieldsFromReader(ProcedureOutputReader procReader)
        {
            DictionaryItemAdapter.FillFieldsFromReader(this, procReader);
        }
    }
}
